package com.memory.demo.Controller;

import com.memory.demo.entity.Soul;
import com.memory.demo.service.PaintService;
import com.memory.demo.service.SearchallService;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

@RestController
public class SearchController {

    @Resource
    private SearchallService searchallService;

    @PostMapping("/search")
    @CrossOrigin
    public List<Soul> getinto(){
        return searchallService.getallSoul();
    }
}
